import request from '@/utils/request';

export type ILoginParams = {
  name: string;
  password: string;
};

export const setLogin = (data: ILoginParams) => {
  return request('/login', {
    method: 'POST',
    data,
  });
};

export function ladpLogin<T>(data: ILoginParams): Promise<T> {
  return request('/v1/auth/ldaplogin', {
    method: 'POST',
    data,
  });
}
